﻿using System;
using System.Collections.Generic;

namespace Models.Models;

/// <summary>
/// 订单
/// </summary>
public partial class SOrder
{
    /// <summary>
    /// 自增id
    /// </summary>
    public uint Id { get; set; }

    /// <summary>
    /// 订单号
    /// </summary>
    public string OrderNo { get; set; } = null!;

    /// <summary>
    /// 用户id
    /// </summary>
    public uint UserId { get; set; }

    /// <summary>
    /// 店铺id
    /// </summary>
    public uint ShopId { get; set; }

    /// <summary>
    /// 收件地址id
    /// </summary>
    public uint ReceiveAddressId { get; set; }

    /// <summary>
    /// 收件人-姓名
    /// </summary>
    public string ReceiveName { get; set; } = null!;

    /// <summary>
    /// 收件人-电话
    /// </summary>
    public string ReceiveTel { get; set; } = null!;

    /// <summary>
    /// 收件人-省
    /// </summary>
    public uint ReceiveProvince { get; set; }

    /// <summary>
    /// 收件人-市
    /// </summary>
    public uint ReceiveCity { get; set; }

    /// <summary>
    /// 收件人-县/区
    /// </summary>
    public uint ReceiveCounty { get; set; }

    /// <summary>
    /// 收件人-详细地址
    /// </summary>
    public string ReceiveAddress { get; set; } = null!;

    /// <summary>
    /// 用户备注
    /// </summary>
    public string UserNote { get; set; } = null!;

    /// <summary>
    /// 快递id
    /// </summary>
    public uint ExpressId { get; set; }

    /// <summary>
    /// 快递单号
    /// </summary>
    public string ExpressNumber { get; set; } = null!;

    /// <summary>
    /// 支付方式id
    /// </summary>
    public uint PaymentId { get; set; }

    /// <summary>
    /// 订单状态（0待确认, 1已确认/待支付, 2已支付/待发货, 3已发货/待收货, 4已完成, 5已取消, 6已关闭）
    /// </summary>
    public byte Status { get; set; }

    /// <summary>
    /// 支付状态（0未支付, 1已支付, 2已退款）
    /// </summary>
    public byte PayStatus { get; set; }

    /// <summary>
    /// 扩展展示数据
    /// </summary>
    public string? ExtensionData { get; set; }

    /// <summary>
    /// 增加的金额
    /// </summary>
    public decimal IncreasePrice { get; set; }

    /// <summary>
    /// 优惠金额
    /// </summary>
    public decimal PreferentialPrice { get; set; }

    /// <summary>
    /// 订单单价
    /// </summary>
    public decimal Price { get; set; }

    /// <summary>
    /// 订单总价(订单最终价格)
    /// </summary>
    public decimal TotalPrice { get; set; }

    /// <summary>
    /// 已支付金额
    /// </summary>
    public decimal PayPrice { get; set; }

    /// <summary>
    /// 支付时间
    /// </summary>
    public uint PayTime { get; set; }

    /// <summary>
    /// 确认时间
    /// </summary>
    public uint ConfirmTime { get; set; }

    /// <summary>
    /// 发货时间
    /// </summary>
    public uint DeliveryTime { get; set; }

    /// <summary>
    /// 取消时间
    /// </summary>
    public uint CancelTime { get; set; }

    /// <summary>
    /// 收货时间
    /// </summary>
    public uint CollectTime { get; set; }

    /// <summary>
    /// 关闭时间
    /// </summary>
    public uint CloseTime { get; set; }

    /// <summary>
    /// 评论时间
    /// </summary>
    public uint CommentsTime { get; set; }

    /// <summary>
    /// 商家是否已评论（0否, 大于0评论时间）
    /// </summary>
    public uint IsComments { get; set; }

    /// <summary>
    /// 用户是否已评论（0否, 大于0评论时间）
    /// </summary>
    public uint UserIsComments { get; set; }

    /// <summary>
    /// 商家是否已删除（0否, 大于0删除时间）
    /// </summary>
    public uint IsDeleteTime { get; set; }

    /// <summary>
    /// 是否打印 0-未打印 1-已打印
    /// </summary>
    public byte IsPrint { get; set; }

    /// <summary>
    /// 用户是否已删除（0否, 大于0删除时间）
    /// </summary>
    public uint UserIsDeleteTime { get; set; }

    /// <summary>
    /// 添加时间
    /// </summary>
    public uint AddTime { get; set; }

    /// <summary>
    /// 更新时间
    /// </summary>
    public uint UpdTime { get; set; }
}
